package com.scs.application.modules.ext.controller;

import com.scs.application.core.model.RestResult;
import com.scs.application.core.mvc.controller.CrudController;
import com.scs.application.modules.ext.entity.HospitalSharePart;
import com.scs.application.modules.ext.service.HospitalSharePartService;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 *  医院配件分享服务层
 */
@RestController
@RequestMapping("/hospital/share_part")
public class HospitalSharePartController extends CrudController<HospitalSharePart, String, HospitalSharePartService>{
    /***
     * @Description：接受数据
     */
    @PostMapping("/receiveData")
    public RestResult receiveData(@RequestBody List<HospitalSharePart> pushList) {
        return RestResult.ok("推送成功", service.receiveData(pushList));
    }
}